<?php defined('InShopNC') or exit('Access Invalid!');?>
<link rel="stylesheet" type="text/css" href="<?php echo RESOURCE_SITE_URL;?>/js/jquery-ui/themes/ui-lightness/jquery.ui.css"  />
<div class="tabmenu">
    <?php include template('layout/submenu');?>
</div>
<div class="ncsc-form-default">

    <form id="add_form" action="index.php?act=store_promotion_book&op=apply_home_save" method="post" enctype="multipart/form-data">


        <dl>
            <dt><i class="required">*</i>开始时间<?php echo $lang['nc_colon'];?></dt>
            <dd>
                <input id="start_time" name="start_time" type="text" value="<?php echo date('Y-m-d H:i');?>" class="text w130" /><em class="add-on"><i class="icon-calendar"></i></em><span></span>
            </dd>
        </dl>
        <dl>
            <dt><i class="required">*</i>结束时间<?php echo $lang['nc_colon'];?></dt>
            <dd>
                <input id="end_time" name="end_time" type="text" value="<?php echo date('Y-m-d H:i', $output['end_time']);?>" class="text w130"/><em class="add-on"><i class="icon-calendar"></i></em><span></span>
                <p class="hint">
                    <?php echo '结束时间不能大于'.date('Y-m-d H:i', $output['end_time']);?>
                </p>

            </dd>
        </dl>
        <dl>
        <dt>产品名称<?php echo $lang['nc_colon'];?></dt>
        <dd>
           <span>
           <?php echo $output['goods_info']['goods_name'];?>
               <input type="hidden" name="goods_id" value="<?php echo $output['goods_id'];?>" />
               <input type="hidden" name="goods_name" value="<?php echo $output['goods_info']['goods_name'];?>" />
           </span>
        </dd>
        </dl>
        <dl>
            <dt>店铺名称<?php echo $lang['nc_colon'];?></dt>
            <dd>
           <span>
           <?php echo $output['goods_info']['store_name'];?>
               <input type="hidden" name="store_name" value="<?php echo $output['store_name'];?>" />
               <input type="hidden" name="store_id" value="<?php echo $output['store_id'];?>" />

               <input type="hidden" name="member_id" value="<?php echo $output['member_id'];?>" />
               <input type="hidden" name="member_name" value="<?php echo $output['member_name'];?>" />
           </span>
            </dd>
        </dl>


        <div class="bottom">
            <label class="submit-border"><input id="submit_button" type="submit" class="submit" value="<?php echo $lang['nc_submit'];?>"></label>
        </div>
    </form>
</div>
<script type="text/javascript" src="<?php echo RESOURCE_SITE_URL;?>/js/common.js" charset="utf-8"></script>
<script src="<?php echo RESOURCE_SITE_URL;?>/js/jquery-ui/i18n/zh-CN.js"></script>
<script src="<?php echo RESOURCE_SITE_URL;?>/js/jquery-ui-timepicker-addon/jquery-ui-timepicker-addon.min.js"></script>
<link rel="stylesheet" type="text/css" href="<?php echo RESOURCE_SITE_URL;?>/js/jquery-ui-timepicker-addon/jquery-ui-timepicker-addon.min.css"  />

<script type="text/javascript">

    $(document).ready(function(){
        $('input[name="start_time"]').datetimepicker({
            controlType: 'select'
        });
        $('input[name="end_time"]').datetimepicker({
            controlType: 'select'
        });
        //页面输入内容验证
        $("#add_form").validate({
            submitHandler:function(form){
                $("#add_form").sumit();
            },
            rules : {
            },
            messages : {
            }
        });
    });
</script>